<?php
include_once '../../Model/M_SubRubro.php';

$subrubro = new M_SubRubro();

$subrubro->setIdRubro($_REQUEST['codigo']);
$lista = $subrubro->searchSubRubro_PorRubro();

/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
?>
<head>
    <style>
        .subbrubro{
            float: left;
            width: 120px;
            height: 70px;
        }
        
        .vista_subrubro2{
                float: left;
                width: 110px;
                height: 90px;
                background: rgb(226,226,226); /* Old browsers */
                background: -moz-linear-gradient(top,  rgba(226,226,226,1) 0%, rgba(219,219,219,1) 50%, rgba(209,209,209,1) 51%, rgba(254,254,254,1) 100%); /* FF3.6+ */
                background: -webkit-gradient(linear, left top, left bottom, color-stop(0%,rgba(226,226,226,1)), color-stop(50%,rgba(219,219,219,1)), color-stop(51%,rgba(209,209,209,1)), color-stop(100%,rgba(254,254,254,1))); /* Chrome,Safari4+ */
                background: -webkit-linear-gradient(top,  rgba(226,226,226,1) 0%,rgba(219,219,219,1) 50%,rgba(209,209,209,1) 51%,rgba(254,254,254,1) 100%); /* Chrome10+,Safari5.1+ */
                background: -o-linear-gradient(top,  rgba(226,226,226,1) 0%,rgba(219,219,219,1) 50%,rgba(209,209,209,1) 51%,rgba(254,254,254,1) 100%); /* Opera 11.10+ */
                background: -ms-linear-gradient(top,  rgba(226,226,226,1) 0%,rgba(219,219,219,1) 50%,rgba(209,209,209,1) 51%,rgba(254,254,254,1) 100%); /* IE10+ */
                background: linear-gradient(to bottom,  rgba(226,226,226,1) 0%,rgba(219,219,219,1) 50%,rgba(209,209,209,1) 51%,rgba(254,254,254,1) 100%); /* W3C */
                filter: progid:DXImageTransform.Microsoft.gradient( startColorstr='#e2e2e2', endColorstr='#fefefe',GradientType=0 ); /* IE6-9 */
                margin: 2px;
                padding: 3px;
                margin-top: 7px;
                text-align: center;
                font-size: 8px;
                font-weight: bold;
            }
</style>
<script type='text/javascript' src='../js/funciones.js'></script>
</head>
<body>
    
    <? for($i=0; $i<count($lista); $i++){ ?>
    <div class="vista_subrubro2">
        <a href="javascript:FAjax('../Pedido/V_Producto.php', 'pedido_der_top', 'codigo=<?=$lista[$i]['id_sub_rubro']?>', 'POST');"> <img height="70" width="100" src="../images/SubRubro/<?=$lista[$i]['imagen'];?>"/></a>
        <?=$lista[$i]['nombre'];?>
    </div>
    <?}?>    
</body>

